package game.entity;

import game.module.hero.bean.Role;
import lion.core.GamePlayer;
import lion.message.MyResponseMsg;

public class Hero extends Role {

	/** 角色的网络连接 */
	private volatile GamePlayer player = null;

	private Integer id;

	private String viewName;

	private short grade;// 等级

	/** 铜币 */
	private int copper;//
	/** 礼金 */
	private int jiaozi;//
	/** 当前的经验值 */
	private long nowExperience;//
	/** 下次升级所需要的经验值 */
	private long nextExperience;//
	/** 姓名 */
	private String name;//
	/** 性别 */
	private byte sex;//
	/** 人物头像 */
	private byte headimg;//
	/** 账户id */
	private int accountId;//

	/** 进攻加点 */
	private int attackAddpoint;//
	/** 防御加点 */
	private int defenceAddpoint;//
	/** 轻身（改为身法）加点 */
	private int lightAddpoint;//
	/** 健体(改为爆发) 加点 */
	private int strongAddpoint;//
	/** 职业类型id */
	private int careerId;

	/** 背包容量 */
	private int bagCapacity = 30;

	public GamePlayer getPlayer() {
		return player;
	}

	public void setPlayer(GamePlayer player) {
		this.player = player;
	}

	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public Integer getAccountId() {
		return accountId;
	}

	public void setAccountId(Integer accountId) {
		this.accountId = accountId;
	}

	public String getViewName() {
		return viewName;
	}

	public void setViewName(String viewName) {
		this.viewName = viewName;
	}

	public void sendMsg(MyResponseMsg msg) {
		if (player != null) {
			player.sendMsg(msg);
		} else {
			System.err.println("player is null!");
		}
	}

	public short getGrade() {
		return grade;
	}

	public void setGrade(short grade) {
		this.grade = grade;
	}

	public int getAttackAddpoint() {
		return attackAddpoint;
	}

	public void setAttackAddpoint(int attackAddpoint) {
		this.attackAddpoint = attackAddpoint;
	}

	public int getDefenceAddpoint() {
		return defenceAddpoint;
	}

	public void setDefenceAddpoint(int defenceAddpoint) {
		this.defenceAddpoint = defenceAddpoint;
	}

	public int getLightAddpoint() {
		return lightAddpoint;
	}

	public void setLightAddpoint(int lightAddpoint) {
		this.lightAddpoint = lightAddpoint;
	}

	public int getStrongAddpoint() {
		return strongAddpoint;
	}

	public void setStrongAddpoint(int strongAddpoint) {
		this.strongAddpoint = strongAddpoint;
	}

	public int getCopper() {
		return copper;
	}

	public void setCopper(int copper) {
		this.copper = copper;
	}

	public int getJiaozi() {
		return jiaozi;
	}

	public void setJiaozi(int jiaozi) {
		this.jiaozi = jiaozi;
	}

	public long getNowExperience() {
		return nowExperience;
	}

	public void setNowExperience(long nowExperience) {
		this.nowExperience = nowExperience;
	}

	public long getNextExperience() {
		return nextExperience;
	}

	public void setNextExperience(long nextExperience) {
		this.nextExperience = nextExperience;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public byte getSex() {
		return sex;
	}

	public void setSex(byte sex) {
		this.sex = sex;
	}

	public byte getHeadimg() {
		return headimg;
	}

	public void setHeadimg(byte headimg) {
		this.headimg = headimg;
	}

	public int getCareerId() {
		return careerId;
	}

	public void setCareerId(int careerId) {
		this.careerId = careerId;
	}

	public int getBagCapacity() {
		return bagCapacity;
	}

	public void setBagCapacity(int bagCapacity) {
		this.bagCapacity = bagCapacity;
	}

}
